velaif820 2.2.0
Loading...
Searching...
No Matches
Vela IF820 Click Driver

API for configuring and manipulating Vela IF820 Click driver. More...

Topics

 Vela IF820 Device Settings
 Settings for registers of Vela IF820 Click driver.
 Vela IF820 MikroBUS Map
 MikroBUS pin mapping of Vela IF820 Click driver.

Functions

void velaif820_cfg_setup (velaif820_cfg_t *cfg)
 Vela IF820 configuration object setup function.
err_t velaif820_init (velaif820_t *ctx, velaif820_cfg_t *cfg)
 Vela IF820 initialization function.
err_t velaif820_generic_write (velaif820_t *ctx, uint8_t *data_in, uint16_t len)
 Vela IF820 data writing function.
err_t velaif820_generic_read (velaif820_t *ctx, uint8_t *data_out, uint16_t len)
 Vela IF820 data reading function.
void velaif820_set_rst_pin (velaif820_t *ctx, uint8_t state)
 Vela IF820 set RST pin function.
void velaif820_reset_device (velaif820_t *ctx)
 Vela IF820 reset device function.
void velaif820_set_rts_pin (velaif820_t *ctx, uint8_t state)
 Vela IF820 set RTS pin function.
uint8_t velaif820_get_cts_pin (velaif820_t *ctx)
 Vela IF820 get CTS pin function.
uint8_t velaif820_get_hwe_pin (velaif820_t *ctx)
 Vela IF820 get HWE pin function.
void velaif820_set_cmd_mode (velaif820_t *ctx)
 Vela IF820 set cmd mode function.
void velaif820_set_data_mode (velaif820_t *ctx)
 Vela IF820 set data mode function.
void velaif820_cmd_action (velaif820_t *ctx, uint8_t *cmd, uint8_t *params)
 Vela IF820 cmd action function.
void velaif820_cmd_set (velaif820_t *ctx, uint8_t *cmd, uint8_t *params)
 Vela IF820 cmd set function.
void velaif820_cmd_get (velaif820_t *ctx, uint8_t *cmd, uint8_t *params)
 Vela IF820 cmd get function.
void velaif820_cmd_profile (velaif820_t *ctx, uint8_t *cmd, uint8_t *params)
 Vela IF820 cmd profile function.
err_t velaif820_read_packet (velaif820_t *ctx)
 Vela IF820 read packet function.

Detailed Description

API for configuring and manipulating Vela IF820 Click driver.

Any initialization code needed for MCU to function properly. Do not remove this line or clock might not be set correctly.

Function Documentation

◆ velaif820_cfg_setup()

void velaif820_cfg_setup ( velaif820_cfg_t * cfg)

Vela IF820 configuration object setup function.

This function initializes Click configuration structure to initial values.

Parameters
[out]cfg: Click configuration structure. See velaif820_cfg_t object definition for detailed explanation.
Returns
Nothing.
Note
The all used pins will be set to unconnected state.

◆ velaif820_cmd_action()

void velaif820_cmd_action ( velaif820_t * ctx,
uint8_t * cmd,
uint8_t * params )

Vela IF820 cmd action function.

This function sends a specified action command to the Click module.

Parameters
[in]ctx: Click context object. See velaif820_t object definition for detailed explanation.
[in]cmd: Command string, see VELAIF820_CMD_x action definitions.
[in]params: Command arguments string (optional).
Returns
None.
Note
None.

◆ velaif820_cmd_get()

void velaif820_cmd_get ( velaif820_t * ctx,
uint8_t * cmd,
uint8_t * params )

Vela IF820 cmd get function.

This function sends a specified get command to the Click module.

Parameters
[in]ctx: Click context object. See velaif820_t object definition for detailed explanation.
[in]cmd: Command string, see VELAIF820_CMD_x set/get definitions.
[in]params: Command arguments string (optional).
Returns
None.
Note
None.

◆ velaif820_cmd_profile()

void velaif820_cmd_profile ( velaif820_t * ctx,
uint8_t * cmd,
uint8_t * params )

Vela IF820 cmd profile function.

This function sends a specified profile command to the Click module.

Parameters
[in]ctx: Click context object. See velaif820_t object definition for detailed explanation.
[in]cmd: Command string, see VELAIF820_CMD_x profile definitions.
[in]params: Command arguments string (optional).
Returns
None.
Note
None.

◆ velaif820_cmd_set()

void velaif820_cmd_set ( velaif820_t * ctx,
uint8_t * cmd,
uint8_t * params )

Vela IF820 cmd set function.

This function sends a specified set command to the Click module.

Parameters
[in]ctx: Click context object. See velaif820_t object definition for detailed explanation.
[in]cmd: Command string, see VELAIF820_CMD_x set/get definitions.
[in]params: Command arguments string.
Returns
None.
Note
None.

◆ velaif820_generic_read()

err_t velaif820_generic_read ( velaif820_t * ctx,
uint8_t * data_out,
uint16_t len )

Vela IF820 data reading function.

This function reads a desired number of data bytes by using UART serial interface.

Parameters
[in]ctx: Click context object. See velaif820_t object definition for detailed explanation.
[out]data_out: Output read data.
[in]len: Number of bytes to be read.
Returns
  • >0 - Number of data bytes read,
  • <=0 - Error/Empty Ring buffer. See #err_t definition for detailed explanation.
Note
None.

◆ velaif820_generic_write()

err_t velaif820_generic_write ( velaif820_t * ctx,
uint8_t * data_in,
uint16_t len )

Vela IF820 data writing function.

This function writes a desired number of data bytes by using UART serial interface.

Parameters
[in]ctx: Click context object. See velaif820_t object definition for detailed explanation.
[in]data_in: Data buffer for sending.
[in]len: Number of bytes for sending.
Returns
  • >=0 - Success,
  • <0 - Error. See #err_t definition for detailed explanation.
Note
None.

◆ velaif820_get_cts_pin()

uint8_t velaif820_get_cts_pin ( velaif820_t * ctx)

Vela IF820 get CTS pin function.

This function returns the clear to send pin logic state.

Parameters
[in]ctx: Click context object. See velaif820_t object definition for detailed explanation.
Returns
Pin logic state.
Note
None.

◆ velaif820_get_hwe_pin()

uint8_t velaif820_get_hwe_pin ( velaif820_t * ctx)

Vela IF820 get HWE pin function.

This function returns the IF820 ready pin logic state.

Parameters
[in]ctx: Click context object. See velaif820_t object definition for detailed explanation.
Returns
Pin logic state.
Note
None.

◆ velaif820_init()

err_t velaif820_init ( velaif820_t * ctx,
velaif820_cfg_t * cfg )

Vela IF820 initialization function.

This function initializes all necessary pins and peripherals used for this Click board.

Parameters
[out]ctx: Click context object. See velaif820_t object definition for detailed explanation.
[in]cfg: Click configuration structure. See velaif820_cfg_t object definition for detailed explanation.
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
None.

◆ velaif820_read_packet()

err_t velaif820_read_packet ( velaif820_t * ctx)

Vela IF820 read packet function.

This function reads a response or event packet from the Click module and stores it in ctx->evt_pkt structure.

Parameters
[in]ctx: Click context object. See velaif820_t object definition for detailed explanation.
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
None.

◆ velaif820_reset_device()

void velaif820_reset_device ( velaif820_t * ctx)

Vela IF820 reset device function.

This function resets the device by toggling the reset pin logic state.

Parameters
[in]ctx: Click context object. See velaif820_t object definition for detailed explanation.
Returns
None.
Note
None.

◆ velaif820_set_cmd_mode()

void velaif820_set_cmd_mode ( velaif820_t * ctx)

Vela IF820 set cmd mode function.

This function sets the command mode by setting the SPP pin to high logic state.

Parameters
[in]ctx: Click context object. See velaif820_t object definition for detailed explanation.
Returns
None.
Note
None.

◆ velaif820_set_data_mode()

void velaif820_set_data_mode ( velaif820_t * ctx)

Vela IF820 set data mode function.

This function sets the data mode by setting the SPP pin to low logic state.

Parameters
[in]ctx: Click context object. See velaif820_t object definition for detailed explanation.
Returns
None.
Note
None.

◆ velaif820_set_rst_pin()

void velaif820_set_rst_pin ( velaif820_t * ctx,
uint8_t state )

Vela IF820 set RST pin function.

This function sets the reset pin logic state.

Parameters
[in]ctx: Click context object. See velaif820_t object definition for detailed explanation.
[in]state: Pin logic state.
Returns
None.
Note
None.

◆ velaif820_set_rts_pin()

void velaif820_set_rts_pin ( velaif820_t * ctx,
uint8_t state )

Vela IF820 set RTS pin function.

This function sets the request to send pin logic state.

Parameters
[in]ctx: Click context object. See velaif820_t object definition for detailed explanation.
[in]state: Pin logic state.
Returns
None.
Note
None.